 <!--contact start-->
<section class="blog" id="blog">
    <div class="container topCon">

      <div class="heading">
          <h2><?php if ( is_category() ) :  single_cat_title( '', true ); else : the_title(); endif; ?></h2>
      </div>

      <div class="row">
        <?php 
          $gridClass = isset(qvaCore::$qvaOptions['design']['choosidebar']) && (qvaCore::$qvaOptions['design']['choosidebar']) == 'no-sidebar' ? 'col-lg-12' : 'col-lg-9';
        ?>
        <?php if (  isset(qvaCore::$qvaOptions['design']['choosidebar']) && (qvaCore::$qvaOptions['design']['choosidebar']) == 'l-sidebar' ) : ?>
        <div class="col-lg-3">
          <div class="sidebar">
            <?php get_sidebar(); ?>
          </div><!-- end sidebar -->
        </div>
        <?php endif; ?>

        <div class="<?php echo $gridClass; ?>">
          <?php 
          $qva_showPosts = get_option("posts_per_page");
         
          $qva_showPosts = isset($qva_showPosts) ? $qva_showPosts : 4;
          $qva_args = array('post_type'=>'post', 'posts_per_page'=>$qva_showPosts, 'post_status'=>'publish', 'paged' => ( get_query_var('paged') ? get_query_var('paged') : 1 ));
         
              query_posts($qva_args);
              if ( have_posts() ) : while( have_posts() ) : the_post();
              ?>
              <div class="post post-single">
                <div class="inner-spacer-right-lrg">

                  <div class="post-media">
                      <?php qva_view_type($post->ID); ?>
                  </div>
                  <div class="post-title">
                    <h3><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3>
                    <?php qva_get_meta_data(); ?>
                  </div>
                </div>

                <div class="post-body">
                  <?php the_excerpt(); ?>
                  <div>
                    <a class="read-more" href="<?php the_permalink(); ?>"><?php _e('read more', QVA_LANG) ?></a>
                  </div>
                </div>

                <?php if ( has_tag() ) : ?>
                 <div class="post-tags">
                    <span class="tags-icon"><i class="fa fa-tags"></i></span>
                    <?php  the_tags('', ', ', '');  ?>      
                  </div> <!-- /post-tags -->
                <?php endif; ?>
              </div>
              <?php 
                endwhile;endif;
             
          ?>
          
          <div class="pagination">
              <?php get_template_part("pagination"); wp_reset_query(); ?>
          </div>
        </div>

        <?php if (  isset(qvaCore::$qvaOptions['design']['choosidebar']) && (qvaCore::$qvaOptions['design']['choosidebar']) == 'r-sidebar' ) : ?>
        <div class="col-lg-3">
          <div class="sidebar">
            <?php get_sidebar(); ?>
          </div><!-- end sidebar -->
        </div>
        <?php endif; ?>

      </div>

    </div>
</section>
